#ifndef __MESSAGE_HPP__
#define __MESSAGE_HPP__

#include "Level.hpp"
#include <thread>

/*
    1.日志输出时间
    2.日志等级
    3.源文件名称
    4.源代码代号
    5.线程ID
    6.日志主体消息
    7.日志器名称
*/

namespace Logs
{
    struct Message
    {
    public:
        time_t _ctime;
        Level::Value _level;
        std::string _file;
        size_t _line;
        std::thread::id _tid;
        std::string _message;
        std::string _logger;

        Message(time_t ctime,
                Level::Value level,
                std::string file,
                size_t line,
                std::string message,
                std::string logger
            )
            :_ctime(ctime)
            ,_level(level)
            ,_file(file)
            ,_line(line)
            ,_tid(std::this_thread::get_id())
            ,_message(message)
            ,_logger(logger)
        {
            ;
        }
    };
}

#endif